/**
	* 用户相关操作
*/
import { request } from "@/request";
import { modifyHttpValue } from '@/utils/modify.js'

// 登录
export const onLogin = data => {
	return request({url: modifyHttpValue('/api/user/login', data), method: 'post'})
}

// 注册
export const onRegister = data => {
	return request({url: '/api/user/register', data, method: 'post'})
}

// 获取用户信息
export const GetUserInfo = data => {
	return request({url: ''})
}

// 成为推广人
export const onPromoter = data => {
	return request({url: '/api/user/becomePromoter', data, method: 'post'})
}
	
// 查询用户是否注册
export const GetUserRegister = data => {
	return request({url: '/api/user/checkUserisregister', data, isDialog: true})
}

// 忘记密码
export const SetUserPassword = data => {
	return request({url: '/api/user/wangjipasswd', data, method: 'post'})
}